#ifndef jihaixuan
#define jihaixuan
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/fs.h>
#include <linux/init.h>
#include <linux/mount.h>
#include <linux/types.h>
#include <linux/slab.h>
#include <linux/uaccess.h>

static ssize_t my_read (struct file * f, char __user * buf, size_t count, loff_t * f_pos);
static ssize_t my_write (struct file * f, const char __user * buf , size_t count, loff_t * f_pos);
static int my_open (struct inode * i, struct file * f);
static int my_release (struct inode * i, struct file * f);
static void init_my_operations(void);
static int my_create(struct mnt_idmap *idmap, struct inode *dir, struct dentry *dentry, umode_t mode, bool b);
static int my_mkdir(struct mnt_idmap * idmap, struct inode *dir, struct dentry * dentry,umode_t mode) ;
static struct inode *myfs_get_inode(struct super_block *sb, const struct inode *dir, int mode, dev_t dev);
static int myfs_fill_super(struct super_block *sb, void *data, int silent);
static struct dentry *myfs_mount(struct file_system_type *fs_type, int flags, const char *dev_name, void *data);
static void myfs_kill_super(struct super_block *sb);
static int __init myfs_init(void);

static void __exit myfs_exit(void);
static struct super_operations myfs_super_ops = {
    .statfs = simple_statfs,  // 获取文件系统的状态
    .drop_inode = generic_delete_inode,  // 使用默认的drop_inode实现
};
static struct inode_operations my_inode_operations;
static struct file_operations my_dir_ops = {
    .open = dcache_dir_open,
    .release = dcache_dir_close,
    .llseek = dcache_dir_lseek,
    .read = generic_read_dir,
    .iterate_shared = dcache_readdir,
    .fsync = noop_fsync,
};;
static struct file_operations my_file_ops ={
    .open = my_open,
    .read = my_read,
    .write = my_write,
    .release = my_release,
};;
#endif